package com.wpf.system.mapper;

import com.wpf.system.entity.RoleMenu;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author ferna
* @description 针对表【role_menu(角色关联权限表)】的数据库操作Mapper
* @createDate 2022-12-15 22:31:16
* @Entity com.wpf.system.entity.RoleMenu
*/
public interface RoleMenuMapper extends BaseMapper<RoleMenu> {

    /**
     * 更新角色权限
     * @param rid 角色ID
     * @param midList 权限ID集合
     * @return int
     */
    int saveRoleMenu(@Param("rid") Long rid , @Param("midList") List<Long> midList);

    /**
     * 删除菜单关联删除
     * @param midList 删除的mid集合
     * @return int
     */
    int deleteRoleMenuByMid(@Param("midList") List<Long> midList);
}




